package com.cw2.behavioral.strategy;

/**
 * 定义主体类
 */
public class TeamGNR {
    private GameStrategy gameStrategy;

    public TeamGNR(GameStrategy gameStrategy) {
        this.gameStrategy = gameStrategy;
    }

    public void startGame() {
        System.out.println("游戏开始");
        // 执行指定的策略
        gameStrategy.warStrategy();
        System.out.println("策略执行已经完成");
    }
}
